package cc.mrbird.management.service;

import cc.mrbird.common.domain.QueryRequest;
import cc.mrbird.common.domain.ResponseBo;
import cc.mrbird.common.service.IService;
import cc.mrbird.management.domain.ManagementInstitutions;
import cc.mrbird.system.domain.Dept;
import cc.mrbird.system.domain.Dict;
import cc.mrbird.system.domain.User;
import org.springframework.cache.annotation.CacheConfig;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;
@CacheConfig(cacheNames = "ManagementInstitutionsService")
public interface ManagementInstitutionsService extends IService<ManagementInstitutions> {
   /* @Cacheable(key = "#p0.toString() + (#p1 != null ? #p1.toString() : '')")*/
    List<ManagementInstitutions> findManaList(ManagementInstitutions managementInstitutions, QueryRequest request);
    ManagementInstitutions findByName(String miName);
    @CacheEvict(allEntries = true)
    void add(ManagementInstitutions managementInstitutions);
    @CacheEvict(key = "#p0", allEntries = true)
    void updateMana(ManagementInstitutions managementInstitutions);
    @Cacheable(key = "#p0")
    ManagementInstitutions findById(Long id);
    @CacheEvict(key = "#p0", allEntries = true)
    void deleteMana(String ids);

    Boolean batchImport(String fileName, MultipartFile file) throws Exception;
}
